

public class testtensor {

	/**
	 * @param args
	 */
	public static void main(String[] args) {
		Matrix a = new Matrix(2,2,0);
		a.setElement(0, 0, new Complex(1,0));
		a.setElement(1, 0, new Complex(2,0));
		a.setElement(0, 1, new Complex(3,0));
		a.setElement(1, 1, new Complex(4,0));
        printMatrix(a);
        
		Matrix b = new Matrix(2,2,0);
		b.setElement(0, 0, new Complex(1,0));
		b.setElement(1, 0, new Complex(1,0));
		b.setElement(0, 1, new Complex(1,0));
		b.setElement(1, 1, new Complex(1,0));
		printMatrix(b);
		
		printMatrix(a.tensorProduct(b));
		System.out.print("\n\n\n");
		printMatrix(a);
		System.out.print("\n");
		printMatrix(b);
		System.out.print("\n");
		printMatrix(a.multiplyMatrix(b));
		System.out.print("\n");
		printMatrix(a.addMatrix(b));

	}
	
	public static void printMatrix(Matrix m){
		/*for (int i = 0; i < m.getHeight(); i++){
			for (int j = 0; j<m.getWidth();j++){
				System.out.print((m.getElement(j, i).getReal()+" "));
			}
			System.out.print("\n");
		}
		*/
		System.out.println(m.toString());
	}

}
